<?php
/**
 * Float filter
 */
class Q_Filter_Float extends Q_Filter_Abstract {

    /**
     * The parameters that were passed to this filter
     */
    protected $_params = array(
        'field' => 0, // default is zero because this allows $filter->filter('some text')
    );
	/**
	 * Do the float filterness
	 */
    public function doFilter($value) {
    
		if ($value != "") return (float) $value;
		return $value;
    
    }

}